package pro.shushi.pamirs.hr.api.model.stat;

import pro.shushi.pamirs.boot.base.ux.annotation.field.UxWidget;
import pro.shushi.pamirs.boot.base.ux.annotation.view.UxTableSearch;
import pro.shushi.pamirs.meta.annotation.Field;
import pro.shushi.pamirs.meta.annotation.Model;
import pro.shushi.pamirs.meta.base.IdModel;

// 模型中UX开头的注解(UxForm/UxTable/UxDetail等)可以不用写，都可在设计器中进行可视化配置; 代码里面写这些注解是为了默认页面的交互

/**
 * 部门人数统计定时任务：pro.shushi.pamirs.hr.core.task.DepartmentStaffStatTask
 */
@Model.model(DepartmentStaffStat.MODEL_MODEL)
@Model(displayName = "部门统计(异步)")
@Model.Advanced(unique = {"departmentCode"})
public class DepartmentStaffStat extends IdModel {

    private static final long serialVersionUID = 5626273740800455515L;

    public static final String MODEL_MODEL = "hr.simple.DepartmentStaffStat";

    @UxTableSearch.FieldWidget(@UxWidget())
    @Field.String
    @Field(displayName = "部门名称")
    private String departmentName;

    @UxTableSearch.FieldWidget(@UxWidget())
    @Field.String
    @Field(displayName = "部门编码")
    private String departmentCode;

    @Field.Integer
    @Field(displayName = "总人数")
    private Long totalStaffCount;

    @Field.Integer
    @Field(displayName = "在职人数")
    private Long staffCount;

    @Field.Integer
    @Field(displayName = "离职人数")
    private Long quitStaffCount;

}
